﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="AddStaff.aspx.cs" Inherits="SWEN_HMS.StaffHousekeepingModule.AddStaff" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">


    <style type="text/css">
        .auto-style2
        {
            width: 100%;
        }
        .auto-style3
        {
            height: 21px;
        }
        .auto-style6
        {
            width: 136px;
        }
        .auto-style7
        {
            height: 21px;
            width: 136px;
        }
        .auto-style9
        {
            width: 243px;
        }
        .auto-style10
        {
            height: 21px;
            width: 243px;
        }
        .auto-style11
        {
            width: 136px;
            height: 26px;
        }
        .auto-style12
        {
            width: 117px;
            text-align: right;
            height: 26px;
        }
        .auto-style13
        {
            width: 243px;
            height: 26px;
        }
        .auto-style14
        {
            height: 26px;
        }
        .auto-style15
        {
            width: 117px;
        }
        .auto-style16
        {
            height: 21px;
            width: 117px;
            text-align: right;
            font-size: small;
        }
        .auto-style17
        {
            width: 117px;
            text-align: right;
        }
        .auto-style18
        {
            height: 20px;
            width: 136px;
        }
        .auto-style19
        {
            height: 20px;
            width: 117px;
            text-align: right;
        }
        .auto-style20
        {
            height: 20px;
            width: 243px;
        }
        .auto-style21
        {
            height: 20px;
        }
    .auto-style22
    {
        width: 117px;
        height: 21px;
    }
    </style>
</asp:Content>
<asp:Content ID="Content5" runat="server" contentplaceholderid="pageTitlePHolder">
    <span class="auto-style1" style="color: #000000">Add Staff Page</span>
</asp:Content>
<asp:Content ID="Content6" runat="server" contentplaceholderid="ContentPlaceHolder1">
        <asp:Panel ID="Panel1" runat="server" BackColor="#FDE3BD" BorderColor="#DEBD92" 
        BorderStyle="Solid">
            
            <br />
            <table class="auto-style2">
                <tr>
                    <td class="auto-style6">
                        <asp:ScriptManager ID="ScriptManager2" runat="server">
                        </asp:ScriptManager>
                    </td>
                    <td class="auto-style15">&nbsp;</td>
                    <td class="auto-style9">&nbsp;</td>
                    <td>&nbsp;</td>
                </tr>
                <tr>
                    <td class="auto-style7"></td>
                    <td class="auto-style16">Required Field<span class="auto-style10" style="color: red">*</span> </td>
                    
                    <td class="auto-style3">&nbsp;</td>
                </tr>
                <tr>
                    <td class="auto-style7">&nbsp;</td>
                    <td class="auto-style16">&nbsp;</td>
                    <td class="auto-style10">
                        <asp:Label ID="lblerrormessage" runat="server" ForeColor="Red"></asp:Label>
                    </td>
                    <td class="auto-style3">&nbsp;</td>
                </tr>
                <tr>
                    <td class="auto-style18"></td>
                    <td class="auto-style19">Staff Name<span class="auto-style10" style="color: red">*</span>:</td>
                    <td class="auto-style20">
                        <asp:TextBox ID="tbxstaffName" runat="server" Width="147px"></asp:TextBox>
                    </td>
                    <td class="auto-style21">
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="tbxstaffName" ErrorMessage="Please enter the staff name." ForeColor="Red" Display="Dynamic"></asp:RequiredFieldValidator>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style6">&nbsp;</td>
                    <td class="auto-style17">Password:</td>
                    <td class="auto-style9">
                        <asp:TextBox ID="tbxPW" runat="server" TextMode="Password" Width="147px"></asp:TextBox>
                        <asp:PasswordStrength ID="tbxPW_PasswordStrength" runat="server" Enabled="True" PreferredPasswordLength="12" TargetControlID="tbxPW">
                        </asp:PasswordStrength>
                    </td>
                    <td>&nbsp;</td>
                </tr>
                <tr>
                    <td class="auto-style6">&nbsp;</td>
                    <td class="auto-style17">Re-type Password:</td>
                    <td class="auto-style9">
                        <asp:TextBox ID="tbxRPW" runat="server" TextMode="Password" Width="147px"></asp:TextBox>
                    </td>
                    <td>
                        <asp:CompareValidator ID="CompareValidator1" runat="server" ControlToCompare="tbxPW" ControlToValidate="tbxRPW" Display="Dynamic" ErrorMessage="These passwords don't match." ForeColor="Red"></asp:CompareValidator>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style11"></td>
                    <td class="auto-style12">Date of Birth (DOB):</td>
                    <td class="auto-style13">
                        <asp:TextBox ID="tbxDate" runat="server" TextMode="Date" Width="147px"></asp:TextBox>
                    </td>
                    <td class="auto-style14"></td>
                </tr>
                <tr>
                    <td class="auto-style11"></td>
                    <td class="auto-style12">Email<span class="auto-style10" style="color: red">*</span>:</td>
                    <td class="auto-style13">
                        <asp:TextBox ID="tbxEmail" runat="server" style="margin-bottom: 0px" Width="147px"></asp:TextBox>
                        <asp:TextBoxWatermarkExtender ID="tbxEmail_TextBoxWatermarkExtender" runat="server" Enabled="True" TargetControlID="tbxEmail" WatermarkText="e.g: staff@hotmail.com">
                        </asp:TextBoxWatermarkExtender>
                    </td>
                    <td class="auto-style14">
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="tbxEmail" Display="Dynamic" ErrorMessage="Please enter staff email." ForeColor="Red"></asp:RequiredFieldValidator>
                        <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ControlToValidate="tbxEmail" Display="Dynamic" ErrorMessage="Invalid Email." ForeColor="Red" ValidationExpression="\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"></asp:RegularExpressionValidator>
                        
                    </td>
                </tr>
                <tr>
                    <td class="auto-style6">&nbsp;</td>
                    <td class="auto-style17">Contact Number<span class="auto-style10" style="color: red">*</span>:</td>
                    <td class="auto-style9">
                        <asp:TextBox ID="tbxContact" runat="server" Width="147px"></asp:TextBox>
                    </td>
                    <td>
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="tbxContact" ErrorMessage="Please enter staff Contact no." ForeColor="Red" Display="Dynamic"></asp:RequiredFieldValidator>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style7"></td>
                    <td class="auto-style16">Address:</td>
                    <td class="auto-style10">
                        <asp:TextBox ID="tbxAddress" runat="server" Height="58px" TextMode="MultiLine" Width="161px"></asp:TextBox>
                    </td>
                    <td class="auto-style3"></td>
                </tr>
                <tr>
                    <td class="auto-style7"></td>
                    <td class="auto-style16">Bank type<span class="auto-style10" style="color: red">*</span>:</td>
                    <td class="auto-style10">
                        <asp:DropDownList ID="ddlBank" runat="server">
                            <asp:ListItem>POSB Current</asp:ListItem>
                            <asp:ListItem>POSB Saving</asp:ListItem>
                            <asp:ListItem>OCBC Current</asp:ListItem>
                            <asp:ListItem>OCBC Saving</asp:ListItem>
                            <asp:ListItem>DBS Current</asp:ListItem>
                            <asp:ListItem>DBS Saving</asp:ListItem>
                        </asp:DropDownList>
                    </td>
                    <td class="auto-style3">
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ControlToValidate="ddlBank" ErrorMessage="Please select a bank type." ForeColor="Red" Display="Dynamic"></asp:RequiredFieldValidator>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style6">&nbsp;</td>
                    <td class="auto-style17">Account Number<span class="auto-style10" style="color: red">*</span>:</td>
                    <td class="auto-style9">
                        <asp:TextBox ID="tbxAccountNO" runat="server" Width="147px"></asp:TextBox>
                       
                        <asp:TextBoxWatermarkExtender ID="tbxAccountNO_TextBoxWatermarkExtender" runat="server" Enabled="True" TargetControlID="tbxAccountNO" WatermarkText="e.g:875635967">
                        </asp:TextBoxWatermarkExtender>
                       
                    </td>
                    <td>
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" ControlToValidate="tbxAccountNO" ErrorMessage="Please enter staff account no." ForeColor="Red" Display="Dynamic"></asp:RequiredFieldValidator>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style6">&nbsp;</td>
                    <td class="auto-style17">Position<span class="auto-style10" style="color: red">*</span>:</td>
                    <td class="auto-style9">
                        <asp:DropDownList ID="ddlPosition" runat="server" AutoPostBack="True" OnSelectedIndexChanged="ddlPosition_SelectedIndexChanged">
                            <asp:ListItem>Reception</asp:ListItem>
                            <asp:ListItem>General Maintenance</asp:ListItem>
                            <asp:ListItem>Security</asp:ListItem>
                            <asp:ListItem>Manager</asp:ListItem>
                            <asp:ListItem>Room Maintenance</asp:ListItem>
                            <asp:ListItem>Estate Maintenance</asp:ListItem>
                        </asp:DropDownList>
                    </td>
                    <td>
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator6" runat="server" ControlToValidate="ddlPosition" ErrorMessage="Please select a position" ForeColor="Red" Display="Dynamic"></asp:RequiredFieldValidator>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style6">&nbsp;</td>
                    <td class="auto-style17">Access Level<span class="auto-style10" style="color: red">*</span>:</td>
                    <td class="auto-style9">
                        <asp:TextBox ID="tbxAccess" runat="server" ReadOnly="True"></asp:TextBox>
                    </td>
                    <td>
                        &nbsp;</td>
                </tr>
                <tr>
                    <td class="auto-style6">&nbsp;</td>
                    <td class="auto-style15">&nbsp;</td>
                    <td class="auto-style9">
                        &nbsp;</td>
                    <td>&nbsp;</td>
                </tr>
                <tr>
                    <td class="auto-style7"></td>
                    <td class="auto-style22"></td>
                    <td class="auto-style10"></td>
                    <td class="auto-style3"></td>
                </tr>
                <tr>
                    <td class="auto-style6">&nbsp;</td>
                    <td class="auto-style15">&nbsp;</td>
                    <td class="auto-style9">
                        <asp:Button ID="btnAdd" runat="server" CssClass="btnCSS" Text="Add" OnClick="btnAdd_Click" />
                        &nbsp;<asp:Button ID="btnCancel" runat="server" CssClass="btnCSS" Text="Cancel" Width="82px" OnClick="btnCancel_Click" CausesValidation="False" />
                    </td>
                    <td>&nbsp;</td>
                </tr>
            </table>
            <br />
            <br />
            <br />
            <br />
    &nbsp;&nbsp;<br />
        </asp:Panel>
    </asp:Content>

